home *** CD-ROM | disk | FTP | other *** search
/ Fritz: All Fritz / All Fritz.zip / All Fritz / FILES / PROGBLER / D86V318B.LZH / D04.DOC < prev    next >
Text File  |  1988-01-13  |  11KB  |  229 lines

  1. CHAPTER 4    D86 CONTROL KEYS
  2.  
  3. D86 has a set of functions invoked by single keys.  Keys which
  4. switch the display (for example, to show a help screen) can be
  5. pressed in any context, to be acted upon immediately.  Other
  6. keys, such as the single-stepping keys, can be invoked any time
  7. D86 is awaiting the beginning of an assembly language command.
  8.  
  9.  
  10. Display Control Keys
  11.  
  12. There are numerous keys that let you control the switchable
  13. window in the upper right corner of the screen.  The F10 and Alt-
  14. F10 keys let you toggle between windows, giving you a "tour" of
  15. what's available.  Various keys accessed by using the "Ctrl" key
  16. as a shift key let you move directly to the window of your
  17. choice.
  18.  
  19. The keys in this section are acted upon in any debugger context,
  20. whether you are in the main command mode or in the middle of one
  21. of the other modes (typing in a debugger command, an immediate-
  22. execute line, a patch-memory line, or a memory window
  23. specification):
  24.  
  25. ALT-F10   Toggles you between Help and Non-Help modes.  If the
  26.           window is showing you a help page, it will switch to
  27.           the last Non-Help page that was displayed.  If not, the
  28.           window switches to the last Help screen displayed for
  29.           the current context.
  30.  
  31.           (HELP key on Wang, F11 key on TI-PC, CTRL-PF5 key on
  32.           Sanyo)
  33.  
  34. F10       In non-help mode, toggles you between the available
  35.           non-help windows: the sign-on/second disassembly
  36.           window, the status window, the memory display window,
  37.           and, if you have a floating-point chip, the floating-
  38.           point display window.
  39.  
  40.           In help mode, toggles you between the help windows
  41.           available in the current context.
  42.  
  43. Ctrl-I    (or TAB) takes you from any other window directly to
  44.           the sign-on/second disassembly window.  This window
  45.           contains the D86 sign-on message until the first time
  46.           that the Instruction Pointer leaves the first
  47.           disassembly page.  From that point on, the sign-on
  48.           message is no longer available, and you get a second
  49.           disassembly page instead.
  50.  
  51. Ctrl-S    Takes you from any other window directly to the
  52.           debugger status window.
  53.  
  54. Ctrl-F    Takes you from any other window directly to the
  55.           floating point display window, if your machine has a
  56.           floating point chip in operation.  If not, this key is
  57.           ignored.
  58.  
  59. Ctrl-N    If you have a memory display window in sight, this key
  60.           advances to the Next window full of memory.
  61.                                                               4-2
  62.  
  63.           If you do not have a memory display window, but do have
  64.           at least one memory line specification, this key takes
  65.           you from any other window to the memory display window,
  66.           continuing from the end of the last line display.
  67.  
  68.           If you have no memory line specifications set up, this
  69.           key is ignored.
  70.  
  71. Ctrl-P    If you have a memory display window in sight, this key
  72.           retreats the pointer to memory displayed, by the amount
  73.           displayed in the window.  If all the memory formats
  74.           specified generate a fixed-size display (such as the
  75.           B,W,T formats), then this will effect a "Previous page"
  76.           function.  If there are formats producing a variable-
  77.           size display (such as the N,D,C,S,L formats), then the
  78.           retreat will be a probably imperfect approximation to
  79.           an appropriate "Previous page" amount.
  80.  
  81.           If you do not have a memory display window, this key
  82.           will go to one, just like the Ctrl-N key.
  83.  
  84. Ctrl-Q    If you are not displaying a help window, this key takes
  85.           you to the last help window that was displayed for the
  86.           current context.  If you are already displaying a help
  87.           window, this key toggles through all the help windows
  88.           available for this context.
  89.  
  90.  
  91. Instruction Pointer Positioning Control Keys
  92.  
  93. All the remaining keys in this chapter can be invoked any time
  94. the debugger is in its main command mode, awaiting the first key
  95. of a debugger command or immediate assembly line.  They change
  96. the value of the Instruction Pointer (IP register), and thus they
  97. change the disassembly display.
  98.  
  99. None of the control keys in this section cause any program code
  100. to be executed, other than the equivalent of a JMP instruction,
  101. to the place that the disassembly cursor winds up.
  102.  
  103. WARNING: On some debuggers, you can change the location of what
  104. is being disassembled without changing the IP register value.
  105. I've decided on a "what you see is what you get" philosophy,
  106. since you may well be moving the IP cursor to effect a jump in
  107. the program (for example, you might use the Down-Arrow key to
  108. experimentally skip over the execution of one or more
  109. instructions in the program).  If your intention was just to look
  110. around the program before continuing execution at the place you
  111. left off, you may use the HOME key to return to the place where
  112. execution last halted.
  113.  
  114. Down-Arrow   Jump to the instruction following the current one.
  115.              Visually, the disassembly cursor moves down by one
  116.              instruction line.
  117.                                                               4-3
  118.  
  119. Up-Arrow     Jump to the instruction preceding the current one.
  120.              Visually, the disassembly cursor moves up by one
  121.              instruction line.  NOTE that the implementation of
  122.              this function is a little tricky, since it's
  123.              impossible to reliably disassemble backwards.  What
  124.              D86 does is retreat a fixed, fair-sized distance,
  125.              disassemble forward until the current instruction is
  126.              reached, and take the instruction disassembled just
  127.              before the current one.  If there is non-instruction
  128.              code in memory shortly before the current position,
  129.              the synchronization may fail, and this instruction
  130.              may put you in the middle of a previous instruction
  131.              instead of the beginning.  If this happens, you may
  132.              adjust by using the Ctrl-D or Ctrl-U keys.
  133.  
  134. Ctrl-D       This key is identical to the Down-Arrow key, except
  135.              the jump forward is just one byte, instead of a full
  136.              (usually multibyte) instruction.  (IP is
  137.              incremented.)  You use this key when you think
  138.              you've landed in the middle, rather than the start,
  139.              of an instruction.
  140.  
  141. Ctrl-U       This key decrements IP, moving the cursor "Up" by
  142.              one byte's worth.  Like Ctrl-D, it is used to
  143.              manually synchronize disassembly.
  144.  
  145. Pg Dn        Jump to the next disassembly page, at the memory
  146.              location immediately following this page.  Repeated
  147.              pressing of this key allows you to scan program code
  148.              quickly.
  149.  
  150.              (Alt-Down-Arrow on the TI-PC)
  151.  
  152. Pg Up        Jump to the previous disassembly page, ending with
  153.              the instruction just before the top instruction on
  154.              the current page.  NOTE the warning given with the
  155.              Up-Arrow description, about possible synchronization
  156.              problems, applies here as well.
  157.  
  158.              (Alt-Up-Arrow on the TI-PC)
  159.  
  160. Home         If you have moved the IP cursor since the last
  161.              program instruction executed, then this key returns
  162.              IP to that spot.  If you are already at that spot,
  163.              this key returns you to the program's starting
  164.              location.  For COM files, this is always location
  165.              0100 in the original code segment.  For EXE files,
  166.              this location was derived from the EXE header
  167.              record.  Note that repeated pressing of HOME will
  168.              cause IP to alternate between the two locations, so
  169.              you can't mess yourself up by pressing the key one
  170.              too many times-- just press it again.
  171.  
  172. Ctrl-E       Jump to the End of the program, as determined when
  173.              it was loaded, and possibly advanced if the program
  174.              was patched from the end.
  175.                                                               4-4
  176.  
  177. Program Execution Control Keys
  178.  
  179. F1           Single step the current instruction.  If the
  180.              instruction is a call, go into the procedure to
  181.              single step it.  If you want the entire procedure
  182.              executed on a single keystroke, use the F2 key.
  183.  
  184. F2           Procedure step: start program, trapping at the
  185.              instruction following the current one.  This is used
  186.              for executing a procedure call all at once; for
  187.              breaking out of a loop; and for executing a repeated
  188.              string operation all at once.
  189.  
  190. F4           Start the program, setting a trap at the destination
  191.              of the conditional jump instruction currently
  192.              pointed to.  If we are not pointing to a conditional
  193.              jump, then we single step.
  194.  
  195. F6           Start the program, setting a trap at the address on
  196.              top of the stack (hopefully a procedure return
  197.              address).
  198.  
  199.  
  200. Special Action Control Keys
  201.  
  202. F3           Repeat the last typed-in assembly language or
  203.              debugger command
  204.  
  205. F7           Enter the Patch Memory mode, described in Chapter 3.
  206.  
  207. Shift-F7     Mark the current CS:IP memory location, for use by a
  208.              following F debugger line command.  F can either
  209.              return to this location, or find memory bytes that
  210.              match the ones at this location.
  211.  
  212.              (Ctrl-7 on the Sanyo)
  213.  
  214. Alt-F9       If you have a Color video board, your debugger
  215.              display may become corrupted by the program's
  216.              console output.  If it does, press Alt-F9 to
  217.              eliminate the corruption.  This key exists only
  218.              temporarily; on later versions of D86, the
  219.              corruption will be corrected automatically.
  220.  
  221.              (Ctrl-Shift-PF4 on the Sanyo)
  222.  
  223. Ctrl-T       Reset the debugger's internal Top-of-Stack pointer
  224.              to the current SP value.  This will cause the
  225.              current stack display to become empty, so that
  226.              subsequently pushed values will appear by themselves
  227.              on the stack display.
  228.  
  229.